package cn.jsj.finance.bank;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import cn.jsj.object.LawyerAssiNames;
import cn.jsj.utils.SysLogger;

/**
 * 加载所有律师助理姓名处理类
 * @author LI
 *
 */
 public class LawyerAssiNamesRequest extends javax.servlet.http.HttpServlet implements javax.servlet.Servlet {
	 public void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
		// 调试信息
		 cn.jsj.utils.SysLogger.PrintInfo("加载所有律师助理姓名！！！");

		 //新建律师助理辅助类
		 cn.jsj.object.LawyerAssiNames lan=new cn.jsj.object.LawyerAssiNames();

		 //加载所有律师助理姓名
		 java.util.List<cn.jsj.object.LawyerAssiNames> lanList=new java.util.LinkedList<LawyerAssiNames>();
		 //新建律师助理操作对象
		 cn.jsj.dao.TblLawyAssistantDAO tlad=new cn.jsj.dao.TblLawyAssistantDAO();
		 lanList=tlad.getLawyerAssNames();

		 	//转换成JSON型数据
			cn.jsj.utils.ProduceJsonData pjd=new cn.jsj.utils.ProduceJsonData();
			//1：没有意义
			String jsonData=pjd.jsonFromList(lanList, 1);
			//调试信息
			SysLogger.PrintInfo(jsonData);
			//输出到客户端
			java.io.PrintWriter pw=response.getWriter();
			pw.println(jsonData);
			pw.flush();
			pw.close();

	}
}